import React, { Component } from 'react';

import { LoginApi } from '../../utils/http'

import './login.scss';
export default class Login extends Component {
    login() {
        console.log(1);
        LoginApi('天后').then(res=>{
            console.log(res);
        })
    }
    render () {
        return (
            <div id='login'>
                <div className='content'>
                    <p className='title'>登 录</p>
                    <div action="#" className='form'>
                        <div className='formItem'>
                            <label className='label'>账号：</label>
                            <input type="text" />
                        </div>
                        <div className='formItem'>
                            <label className='label'>密码：</label>
                            <input type="password" />
                        </div>
                        <button className='loginBtn' onClick={()=>this.login()}>登录</button>
                    </div>
                </div>
            </div>
        )
    }
}